package com.ningxia.water.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;

import java.time.LocalDateTime;
import java.io.Serializable;

import com.fasterxml.jackson.annotation.JsonFormat;
import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;

/**
 * <p>
 *
 * </p>
 *
 * @author hz
 * @since 2021-03-15
 */
@Data
@EqualsAndHashCode(callSuper = false)
@JsonIgnoreProperties(value = { "handler" })
@Accessors(chain = true)
public class TsMeter implements Serializable {

    private static final long serialVersionUID = 1L;

    @TableId(value = "meter_id", type = IdType.AUTO)
    private Integer meterId;

    /**
     * 设备编号
     */
    private String meterCode;

    /**
     * 设备名称
     */
    private String meterName;

    /**
     * 1：正常 0：不正常
     */
    private Integer status;

    /**
     * 型号
     */
    private String meterNo;

    /**
     * 安装时间
     */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private LocalDateTime createTime;

    public TsMeter() {
    }

    public TsMeter(String meterCode, String meterName, Integer status, String meterNo, LocalDateTime createTime) {
        this.meterCode = meterCode;
        this.meterName = meterName;
        this.status = status;
        this.meterNo = meterNo;
        this.createTime = createTime;
    }
}
